<style>
    .column_options li {
        display: inline-block;
        width: 200px;
        margin-right: 10px;
        margin-bottom: 3px;
    }
    
    .column_options li label {
        font-weight: normal;
    }
    
    #column_options_dialog {
        width: 750px;
    }
</style>

<div id="column_options_dialog" class="modal-dialog">
    <div class="modal-content">
        <div class="modal-header">
            <button type="button" class="close" data-dismiss="modal">&times;</button>
            <h4 class="modal-title">Report Column Settings</h4>
            <p>Choose the columns you would like to see appear in the report below</p>
        </div>
        <div class="modal-body">
            <ul class="column_options">
                <?php foreach ($column_options as $column) { ?>
                    <li>
                        <label for="">
                            <?php 
                            $checked = "";
                            foreach($report_columns as $report_column) {
                                if( $report_column['report_column_option_id'] == $column['ReportColumnOption']['id'] ) {
                                    $checked = "checked";
                                }
                            }
                            ?>
                            <input type="checkbox" <?php echo $checked; ?> data-field="<?php echo $column['ReportColumnOption']['field_name']; ?>" data-label="<?php echo $column['ReportColumnOption']['display_name']; ?>" value="<?php echo $column['ReportColumnOption']['id']; ?>" /> 
                            <?php echo $column['ReportColumnOption']['display_name']; ?>
                        </label>
                    </li>
                <?php } ?>
            </ul>
        </div>
        <div class="modal-footer">
            
            <a href="#" class="btn btn-primary" id="save_apply">Save & Apply</a>
            <!--<a href="#" class="btn btn-warning" id="set_as_default">Set As Default</a>-->
            <a href="#" class="btn btn-white" data-dismiss="modal">Close</a>
        </div>
    </div><!-- /.modal-content -->
</div><!-- /.modal-dialog -->